<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@include file="/common/taglib.jsp"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<script type="text/javascript" src="js/jquery.js"></script>
<script type="text/javascript" src="js/aa.js"></script>
<link rel="stylesheet" href="front/css/common.css" type="text/css" />

</head>
<body>
<html:form action="maintainVehicleAction" method="post">
	<html:hidden property="tableID" styleId="tableID" value="" />
	<input type="hidden" name="callMethod" id="callMethod" styleId="callMethod"	value="getDataList" />
	<div >
	<div>
		此处查找不支持姓名和身份证号的模糊查找，请完整输入姓名或者身份证号。
	</div>

	<div >姓名：
	<html:text property="userVO.user_name_search" maxlength="10"	styleId="userVO.user_name_search" />
	身份证号：<html:text property="userVO.user_sn_search"		styleId="userVO.user_sn_search"  />
	业务员：<html:select property="userVO.buserid_search"			styleId="userVO.buserid_search">
					<option value="-1">请选择业务员</option>
					<html:options collection="ywyList" labelProperty="username"	property="id"/>
				</html:select>
				
				年份：<html:select property="userVO.year_search"			styleId="userVO.year_search">
					<html:option value="-1">请选择年份</html:option>
					<html:option value="2011">2011</html:option>
					<html:option value="2012">2012</html:option>
					<html:option value="2013">2013</html:option>
					<html:option value="2014">2014</html:option>
					<html:option value="2015">2015</html:option>
				</html:select>
				
				月份：<html:select property="userVO.month_search"			styleId="userVO.month_search">
				<html:option value="-1">请选择月份</html:option>
					<html:option value="1">1月份</html:option>
					<html:option value="2">2月份</html:option>
					<html:option value="3">3月份</html:option>
					<html:option value="4">4月份</html:option>
					<html:option value="5">5月份</html:option>
					<html:option value="6">6月份</html:option>
					<html:option value="7">7月份</html:option>
					<html:option value="8">8月份</html:option>
					<html:option value="9">9月份</html:option>
					<html:option value="10">10月份</html:option>
					<html:option value="11">11月份</html:option>
					<html:option value="12">12月份</html:option>
				</html:select>
				
<html:submit property="cz">查找</html:submit>
	<div ></div>
	</div>
	
	
	<div id="man_zone">
	<table width="99%" border="0" align="center" cellpadding="3"	cellspacing="1" class="table_style">
		<tr>
			<th class="left_title_3" width="5%">&nbsp;&nbsp;序号&nbsp;&nbsp;</th>
			<th class="left_title_3">&nbsp;&nbsp;姓名&nbsp;&nbsp;</th>
			<th class="left_title_3">&nbsp;&nbsp;身份证&nbsp;&nbsp;</th>
			<th class="left_title_3">联系方式</th>
			<th class="left_title_3">所属区域</th>
			<th class="left_title_3">车型</th>
			<th class="left_title_3">车价</th>
			<th class="left_title_3">首付款</th>
			<th class="left_title_3">贷款额</th>
				<th class="left_title_3">创建时间</th>
				<th class="left_title_3">状态</th>
				<th class="left_title_3">操作</th>	
			
		</tr>

		<nested:iterate id="user" name="dateList" indexId="index">
			<tr >
			<td style="text-align: center;">
			<%=index+1 %>
			
		</td>
				<td><nested:write name="user" property="user_name" /></td>
				<td><nested:write name="user" property="user_sn" /></td>
				<td><nested:write name="user" property="user_phone" /></td>
				<td><nested:write name="user" property="area" /></td>
				<td><nested:write name="user" property="car" /></td>
				<td><nested:write name="user" property="jg" /></td>
				<td><nested:write name="user" property="shoufu" /></td>
				<td><nested:write name="user" property="dke" /></td>
				<td>
							<nested:write name="user" property="submit_time"/>
						</td>
						
						<td >
						
						<logic:equal value="1" name="user" property="workflowid">
								退回
							</logic:equal>
							<logic:equal value="2" name="user" property="workflowid">
								待业务经理处理
							</logic:equal>
							<logic:equal value="3" name="user" property="workflowid">
								待征信员处理
							</logic:equal>
							<logic:equal value="4" name="user" property="workflowid">
								待审核员处理
							</logic:equal>
							<logic:equal value="5" name="user" property="workflowid">
								待总经理处理
							</logic:equal>
							<logic:equal value="6" name="user" property="workflowid">
								待客审员处理
							</logic:equal>
							<logic:equal value="7" name="user" property="workflowid">
								待总经理处理
							</logic:equal>
							<logic:equal value="8" name="user" property="workflowid">
								单据已到财务员处
							</logic:equal>
							<logic:equal value="999" name="user" property="workflowid">
								单据取消
							</logic:equal>
							
							<logic:equal value="9999" name="user" property="workflowid">
								单据已封存
							</logic:equal>
						</td>
				<td><input
							type="button" value="删除" style="width: 40px;"
							onclick="deleteUser('<nested:write name="user" property="user_name"/>','<nested:write name="user" property="id"/>')">
							
							<input
							type="button" value="查看" style="width: 40px;"
							onclick="getUserInfo('<nested:write name="user" property="id"/>')">
							
							
							</td>

			</tr>
		</nested:iterate>

	</table>
	</div>
	
	
	<div style="text-align: right;">
	<% Integer  dataTotal=new Integer(request.getAttribute("total").toString());
		Integer maxCount=new Integer(request.getAttribute("maxCount").toString());
	
	%>
	
	<pg:pager	
		url=""
			isOffset="true"
		    items="<%=dataTotal%>"
			maxPageItems="<%=maxCount%>"
    		maxIndexPages="10"
		    export="offset,currentPageNumber=pageNumber"
		    scope="request">
		<pg:param name="index"/>
		<pg:param name="maxPageItems"/>
		<pg:param name="maxIndexPages"/>
		
		<br>
		<pg:index>
		<jsp:include page="/common/simple.jsp" flush="true"/>
		</pg:index>
		</pg:pager>
	</div>
	</div>
</html:form>
<script type="text/javascript">
	function deleteUser(name, id) {
		if (confirm("确定要删除" + name + "的资料吗？,删除后不可恢复，请再次确认！")) {
			$('#callMethod').val('deleteUser');
			$('#tableID').val(id);
			$("form").submit();
		}
	}

	function getUserInfo(id) {
		$('#callMethod').val('getUserInfo');
		$('#tableID').val(id);
		$("form").submit();
	}
	
</script>


</body>
</html>